import { createI18n } from 'vue-i18n'
import zh from './langs/zh'
import en from './langs/en'
import tc from './langs/tc'

const i18n = createI18n({
  legacy: false,  // 处理报错信息
  // locale: 'zh',
  locale: localStorage.getItem('lang') || 'zh',
  messages: {
    zh,
    en,
    tc
  }
})

export default i18n